package com.liushuang.service;

import com.liushuang.po.Blog;
import com.liushuang.vo.BlogQuery;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;

import java.util.List;
import java.util.Map;

/**
 * @author liushuang
 * @create 2020-10-04-20:36
 * description:
 */
public interface BlogService {

    Blog getBlog(Long id);

    Page<Blog> listBlog(Pageable pageable, BlogQuery blog);

    Blog saveBlog(Blog blog);

    Blog updateBlog(Long id,Blog blog);

    void deleteBlog(Long id);

    Page<Blog> listBlog(Pageable pageable);

    List<Blog> listRecommendBlogtop(Integer size);

    Page<Blog> listBlog(String query, Pageable pageable);

    Blog getAndConvert(Long id);

    Page<Blog> listBlog(Long id, Pageable pageable);

    Map<String, List<Blog>> archiveBlog();

    Long countBlog();
}
